home *** CD-ROM | disk | FTP | other *** search
/ Shareware Grab Bag / Shareware Grab Bag.iso / 007 / turbo_tk.arc / MENUDEM.PAS < prev    next >
Pascal/Delphi Source File  |  1988-02-01  |  1KB  |  57 lines

  1. Program Menu_Demo;
  2.  
  3. Uses CRT, FastTTT, DOS, WinTTT, KeyTTT, MenuTTT;
  4.  
  5. var
  6.   M : menu_record;
  7.   Choice, Retcode : integer;
  8.   Ch : char;
  9.  
  10. Procedure Define_M;
  11. begin
  12.     With M do
  13.     begin
  14.         Heading1 := 'TechnoJocks';
  15.         Heading2 := 'Menu';
  16.         Topic[1]  := '  Help';
  17.         Topic[2]  := '  Load Database';
  18.         Topic[3]  := '  Re-index Database ';
  19.         Topic[4]  := '  Input new Data';
  20.         Topic[5]  := '  Save Database';
  21.         Topic[6]  := '  Print Reports';
  22.         Topic[7]  := '  Quit';
  23.         TotalPicks := 7;
  24.         PicksPerLine := 1;
  25.         AddPrefix := 3;
  26.         TopleftXY[1] := 0;
  27.         TopLeftXY[2] := 4;
  28.         BoxType := 5;
  29.         Margins := 5;
  30.         Colors[1] := white;
  31.         Colors[2] := red;
  32.         Colors[3] := lightgray;
  33.         Colors[4] := blue;
  34.         Colors[5] := lightcyan;
  35.         AllowEsc := true;
  36.     end;
  37. end;
  38.  
  39. begin
  40.     Fillscreen(1,1,80,25,white,blue,chr(177));
  41.     ClearLine(25,white,black);
  42.     WriteCenter(25,lightgray,black,'TechnoJocks Turbo Toolkit');
  43.     Choice := 1;
  44.     Define_M;
  45.     DisplayMenu(M,False,Choice,Retcode);
  46.     writeln;
  47.     GotoXY(1,20);
  48.     If Retcode = 0 then
  49.        Writeln('You chose option ',Choice)
  50.     else
  51.        Writeln('You escaped!');
  52.     WriteAT(1,22,white,black,'Run DemoTTT.exe for the main demo program');
  53.     WriteAT(1,23,white,black,'Technojocks Turbo Toolkit v4.0');
  54.     Ch := Readkey;
  55. end.
  56.  
  57.